﻿using System;
using dk.Helper.Base;

namespace dk.Helper.Controls
{
    public partial class AllyControl
    {
        public AllyControl(IAlly ally)
        {
            Ally = ally;
            InitializeComponent();
            btnSelect.Text = ally.Tag;
        }

        public IAlly Ally { get; private set; }

        public event EventHandler Removing;

        private void OnRemoving(EventArgs e)
        {
            if (Removing != null) Removing(this, e);
        }

        protected void mnuRemoveControl_Click(object sender, EventArgs e)
        {
            OnRemoving(new EventArgs());
        }
    }
}